Skip to content

[ws-manager-bridge] update prebuild state properly #7968

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 3, 2022
Merged

Conversation

AlexTugarev
Copy link
Member

@AlexTugarev AlexTugarev commented Feb 2, 2022

ws-manager-bridge is periodically checking for the actual state of prebuilds which according to entries in the DB should be running.

this PR adds missing state updates to prebuild infos which are derived from workspaces instances.

Fix missing status updates for prebuilds.

@codecov
Copy link

codecov bot commented Feb 2, 2022

Codecov Report

Merging #7968 (120452d) into main (8cecf63) will decrease coverage by 1.26%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #7968      +/-   ##
==========================================
- Coverage   11.46%   10.20%   -1.27%     
==========================================
  Files          20       18       -2     
  Lines        1177     1009     -168     
==========================================
- Hits          135      103      -32     
+ Misses       1039      905     -134     
+ Partials        3        1       -2     
Flag Coverage Δ
components-gitpod-cli-app 10.20% <ø> (ø)
components-local-app-app-darwin-amd64 ?
components-local-app-app-darwin-arm64 ?
components-local-app-app-linux-amd64 ?
components-local-app-app-linux-arm64 ?
components-local-app-app-windows-386 ?
components-local-app-app-windows-amd64 ?
components-local-app-app-windows-arm64 ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
components/local-app/pkg/auth/auth.go
components/local-app/pkg/auth/pkce.go

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 8cecf63...120452d. Read the comment docs.

@laushinka
Copy link
Contributor

laushinka commented Feb 2, 2022

@AlexTugarev Is this ready for review or still WIP? 🙏🏽

@@ -325,7 +325,7 @@ export class WorkspaceManagerBridge implements Disposable {
// prebuilds are an EE feature - we just need the hook here
}

protected async controlPrebuildInstance(instance: WorkspaceInstance): Promise<void> {
protected async stopPrebuildInstance(ctx: TraceContext, instance: WorkspaceInstance): Promise<void> {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

renaming, because this function is called in a single context, i.e. only when the status of a prebuild workspace instance is adjusted.

@roboquat
Copy link
Contributor

roboquat commented Feb 3, 2022

LGTM label has been added.

Git tree hash: 86f41e456efc10d99a7562c76e8fdb18bfa21550

@laushinka
Copy link
Contributor

/approve no-issue

@roboquat
Copy link
Contributor

roboquat commented Feb 3, 2022

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: laushinka

Associated issue requirement bypassed by: laushinka

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@roboquat roboquat merged commit 4a56406 into main Feb 3, 2022
@roboquat roboquat deleted the at/prebuild-state branch February 3, 2022 12:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants